1 #include "SettingsInit.h"
5 SettingsInit::SettingsInit(FileIO
* f
, ResourceMaster
* r
)
10 int settings
= fio
->loadUserData(3);
12 screenRes
= (settings
/ 1000) % 10;
13 sfxVol
= (settings
/ 100) % 10;
14 bgmVol
= (settings
/ 10) % 10;
15 language
= (settings
/ 1) % 10;
17 loadLangauges(language
);
23 SettingsInit::~SettingsInit()
27 void SettingsInit::loadLangauges(int la
) {
29 case 1: fio
->loadLanguage("Language/EN.txt"); break;
30 case 2: fio
->loadLanguage("Language/FR.txt"); break;
31 case 3: fio
->loadLanguage("Language/JP.txt"); break;
32 default: fio
->loadLanguage("Language/EN.txt"); break;
35 void SettingsInit::setSfxVol(int vol
) {
37 rsc
->sptr
->setVolume(2);
40 rsc
->sptr
->setVolume(vol
);
42 std::cout
<< vol
<< "SFX\n";
44 void SettingsInit::setBgmVol(int vol
) {
46 rsc
->bptr
->setVolume(2);
49 rsc
->bptr
->setVolume(vol
);
51 std::cout
<< vol
<< "BGM\n";
53 int SettingsInit::getResolution() {